<?php
namespace app\admin\controller;

/**
 * Class Dynamic  24小时动态控制器
 * @package app\admin\controller
 *
 */

class Dynamic extends MyController
{
    public function index()
    {
        $current = input('page',1);
        $length = 10;
        $start = ($current-1)*$length;
        $dynamic = db('dynamic')
            ->order('dy_id','DESC')
            ->limit($start,$length)
            ->paginate($length);
        $this->assign([
            'dynamic'=>$dynamic
        ]);
        return view();
    }
}
